<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>

<input type="text" placeholder="半径" id="a">
<input type="text" placeholder="周长" id="b">
<input type="text" placeholder="面积" id="c">

<script>

var p = prompt("请输入圆的半径");

var pi = Math.PI;
//半径
console.log(p);
//周长
console.log(2 * pi * p);
//面积
console.log(p*p*pi);

document.querySelector("#a").value = p;
document.querySelector("#b").value = 2 * pi * p;
document.querySelector("#c").value = p * p * pi;

</script>
</body>
</html>